from django.urls import path
from . import views

urlpatterns = [
    path("", views.PostListView.as_view(), name="index"),
    path('blog/<slug:slug>/', views.PostDetailView.as_view(), name='post-detail'),
    path("post/add/", views.PostCreate.as_view(), name="post-add"),
    path("post/<int:id>/update/", views.change_post, name="post-update"),
    path("post/<int:pk>/delete/", views.PostDelete.as_view(), name="post-delete"),
]